package com.itheima.package2_memory_optical;

public class Girl extends Thread {
    @Override
    public void run() {
            while (Money.money == 100000){
                synchronized (Girl.class){
                //缓存
                //System.out.println("钱没动");
            }
        };
        System.out.println("钱少了");
    }
}
